Robot control

ABSTRACT

A method to control a robot to perform at least one Cartesian or joint space task comprises using quadratic programming to determine joint forces, in particular joint torques, and/or joint accelerations of said robot based on at least one cost function which depends on said task.

CROSS-REFERENCE TO RELATED APPLICATIONS

This application is a national phase application under 35 U.S.C. § 371 of International Patent Application No. PCT/EP2021/054514, filed Feb. 24, 2021 (pending), which claims the benefit of priority to European Patent Application No. EP20159998.2, filed Feb. 28, 2020, the disclosures of which are incorporated by reference herein in their entirety.

TECHNICAL FIELD

The present invention relates to robot control.

BACKGROUND

Modern robots may have at least one of the following features: they may be kinematically redundant, they may be compliant and/or they shall avoid obstacles.

In particular “freeing” or releasing Degrees of Freedom (DOF) may cause task redundancy, i.e. the DOF of the robot n is bigger than the DOF of the task m (n>m). This may also apply for robots with high(er) numbers of DOF and full DOF Cartesian tasks. Consequently, in such redundant cases, robots can perform more than one task at a time.

Compliant robots can in one embodiment be force-guided by a human: a user can push or hand-guide the robot. This may advantageously, in particular easily, fast, stable and/or reliably, be achieved by torque control, i.e. controlling the torques in the robot joints instead of or additional to poses, i.e. positions and/or orientations, and/or velocities.

In some cases it may be desired to avoid collision with static or moving objects, e.g. a second robot or the like.

A preferred application of the present invention may combine two or three of the following: task control, preferably multi-task control, compliance and obstacle avoidance, in particular in human-robot collaboration, e.g. how to deal with the fact that a robot is manually pushed close to a Cartesian obstacle object while it is performing a task. In other words, how can a controller implement that the task(s), e.g. pick-and-place, is/are constantly being pursued while the user still can interact with the compliant robot and objects are avoided?

In this respect in particular one or more of the following challenges may remain:

smooth vs. hard: for torque-controlled robots, tasks should be formulated in terms of forces or joint torques (for the sake of a more compact formulation, pairs of anti-parallel forces, i.e. torques, will sometimes also be called “forces” herein).

smooth task activation: the obstacle avoidance task should receive top priority. Nevertheless, it preferably should not continuously produce a torque but only be switched on when the Cartesian point on the robot is close to its limit. Switching a top-priority task on and off may lead to discontinuous solutions and oscillations.

Multi-level constraints: sometimes, it may be advantageous to realize not only e.g. Cartesian pose, in particular position, limits, but alternatively or additionally Cartesian velocity and/or acceleration limits, joint pose limits, torque limits or the like. If these are implemented in a stack of tasks, one of these limits may be sacrificed for another one.

A pose may comprise, in particular be or denote respectively, an one-, two- or three-dimensional position and/or an one-, two- or three-dimensional orientation. A joint pose thus may in particular be or denote respectively a position or orientation of one or more joints of the robot, in particular an angle of a revolute joint.

If those challenges are not properly dealt with, the robot may either react too weak (Cartesian object not avoided, robot hits the object), too hard (high torque peaks), and/or with jerky behavior and oscillations that prevent the task from being completed.

SUMMARY

The object of the present invention is to improve control or behavior of a robot, preferably to avoid or reduce one or more of the drawbacks and problems discussed above.

This object is achieved in particular by a method and a system or computer program (product) for performing a method as described herein.

According to an aspect of the present invention Quadratic Programming (QP) is used.

One advantage may be the possibility of including inequality constraints. Additionally or alternatively, it may be possible to have different constraints at the same level of priority. The task(s), e.g. following some trajectory, may be formulated as objective function(s) which preferably are minimized depending on relative importance. The priority between tasks could in particular be soft or strict priority as discussed later herein. Preferably, it can be selected between soft and strict priority, in particular dependent or pose and/or position or depending on a user choice. Constraints which are at the same level of priority like joint limit avoidance or obstacle avoidance may be preferably be formulated as inequality constraints which should never be violated.

In particular in order to include joint torque limits, the optimization problem variables may be (the) joint torques τ∈

^(n) and/or joint accelerations {umlaut over (q)}∈

^(n). Equality constraints, inequality constraints and/or objective functions preferably should be (affine) functions of either τ or {umlaut over (q)}.

Quadratic programming (QP) is the process of solving quadratic problems with a convex quadratic cost function, in particular with linear equality and/or inequality constraints and/or box constraints. It may have the following general form where n is the number of variables in the optimization problem and m is the total number of linear equality and inequality constraints:

${{\min\limits_{x}\frac{1}{2}x^{T}{Hx}} + {x^{T}g}}{{lbA} \leq {Ax} \leq {ubA}}{{lb} \leq x \leq {ub}}$

wherein H(x) denotes the positive (semi) definite and symmetric Hessian matrix ∈

^(nxn), g(x) denotes the gradient vector ∈

^(n), A denotes the constraint matrix ∈

^(mxn), lbA and ubA denotes the gradient vector Σ

^(m) (lbA=ubA for equality constraints) and lb and ub denote the box constraints ∈

^(n), upper and lower bounds for the problem variables.

Redundancy Resolution as a Linear Quadratic Problem

A linear least square problem is of the form:

$\min\limits_{x}\frac{1}{2}{{{Ax} - b}}^{2}$

This problem may be transferred to a quadratic problem by rewriting

$\begin{matrix} {{\frac{1}{2}\left( {{Ax} - b} \right)^{T}\left( {{Ax} - b} \right)} = {\frac{1}{2}\left( {{x^{T}A^{T}{Ax}} - {x^{T}A^{T}b} - {b^{T}{Ax}} + {b^{T}b}} \right)}} \\ {= {\frac{1}{2}\left( {{x^{T}A^{T}{Ax}} - {2x^{T}A^{T}b} + {b^{T}b}} \right)}} \end{matrix}$

Since b^(T)b is a constant it can be neglected. Thus the quadratic cost function becomes:

${C(x)} = {{\frac{1}{2}x^{T}A^{T}{Ax}} - {x^{T}A^{T}b}}$

Comparing to the general QP form, H(x)=A^(T)A, g(x)=−A^(T)b

A Cartesian or Joint space task respectively can be formulated as:

f _(t) =J _(t) {umlaut over (q)}+{dot over (J)} _(t) {dot over (q)}

where f_(t) is the desired Cartesian or joint acceleration respectively and J_(t){dot over (J)}_(t){dot over (q)} and {umlaut over (q)} are the task Jacobian, time derivative of the task Jacobian, joint velocities and joint accelerations respectively. The subscript t denotes the task number. In case of a joint space task J_(t) is constant and equal to identity, I.

The problem can be formulated as a least square problem in terms of the joint accelerations {umlaut over (q)}:

$\min\limits_{\overset{¨}{q}}{{{J_{t}\overset{¨}{q}} - \left( {f_{t} - {{\overset{.}{J}}_{t}\overset{.}{q}}} \right)}}^{2}$

In that case, the problem can be written in the quadratic form with H_(t)({umlaut over (q)})=J_(t) ^(T)J_(t) and g_(t)({umlaut over (q)})=−J_(t) ^(T) (f_(t)−{dot over (J)}_(t){dot over (q)}) in Cartesian space control and H_(t)({umlaut over (q)})=I and g_(t)({umlaut over (q)})=−f_(t) in the Joint space control.

The upper and lower bounds for the optimization problem, ub and lb may preferably be:

${{ub} = \begin{pmatrix} \tau_{max} \\ {\overset{¨}{Q}}_{max} \end{pmatrix}},{{lb} = \begin{pmatrix} \tau_{min} \\ {\overset{¨}{Q}}_{min} \end{pmatrix}}$

where τ_(min) and τ_(max) are the lower and upper bounds for the joint torques and {umlaut over (Q)}_(min) and {umlaut over (Q)}_(max) are the lower and upper bounds for the joint accelerations, preferably after reshaping using limits of joint pose, velocity and/or acceleration (see below).

For dynamic consistency, the robot's joint space dynamic equation M{umlaut over (q)}+g({dot over (q)}, q)+c(q)=τ with the mass matrix M may be included as an (in)equality constraint:

${g + c} \leq {\left( {I - M} \right)\begin{pmatrix} \tau \\ \overset{¨}{q} \end{pmatrix}} \leq {g + c}$

Limits in the Cartesian space and/or obstacle avoidance may be augmented to the constraint matrix A and constraint vectors IbA and ubA:

A=[0 J _(c)]

where 0 is a zero matrix with the same size of J_(c). The constraint vector may be

ubA=({umlaut over (X)} _(max)),lbA=({umlaut over (X)} _(min))

wherein {umlaut over (X)} denotes a Cartesian acceleration of the robot, e.g. its TCP, end effector or flange respectively or the like.

The output will thus be optimal torque and/or joint accelerations that can command the robot.

The problem can analogously or likewise be formulated as a least square problem in terms of the joint accelerations q and forces, in particular torques, as follows according to one embodiment respectively:

${\min\limits_{\overset{¨}{q},\tau}{{{J_{t}\overset{¨}{q}} - \left( {{\overset{¨}{x}}_{t} - {{\overset{.}{J}}_{t}\overset{˙}{q}}} \right)}}^{2}} + {w{{\overset{¨}{q} - {\overset{¨}{q}}_{d}}}^{2}}$

subject to

τ=M(q){umlaut over (q)}+h({dot over (q)},q)+g(q)

τ_(m) ≤τ≤T _(max)

{umlaut over (c)} _(min) ≤J _(c) {umlaut over (q)}+{dot over (J)} _(c) {dot over (q)}≤{umlaut over (c)} _(max)

where M, g and h are the mass or inertia matrix respectively, the gravity and the Coriolis forces respectively. The desired acceleration can be defined given the error dynamics

{umlaut over (x)} _(d) +k _(p) Δx+k _(d) Δ{dot over (x)}

according to one embodiment where Δx is the error x_(d)−x_(c) between the desired pose)(a and the current pose x_(c).

In particular if interaction/compliant behaviour is desired, the robot may commanded by torque.

Alternatively, in particular if the robot shall move accurate, the optimal joint acceleration can be integrated, thus yielding desired joint pose for every control cycle.

Thus, according to one embodiment different kinds of constraints, in particular force, in particular torque, acceleration, velocity and/or pose limits in joint and/or Cartesian space and/or static and/or moving obstacles, can be ensured while trying to perform at least one task, in particular a set of tasks, and with or without physical human robot interaction.

Quadratic programming (QP) may in particular have the advantage of including a set of constraints and keeping all respected while minimizing a cost function.

Several tasks in one cost function may lead to a dependency on chosen weights and it may be necessary to write the constraints to be linear with the variable to be minimized. E.g. if one minimizes a function depending on torque, f(τ), the it is easy to limit forces, but not as easy to limit poses or velocities. Furthermore, if there arises a conflict between constraints one must be sacrificed by the other one (or the robot should stop if a conflict is encountered). Using quadratic programming can solve this problem and in particular new constraints like torque limits or static or moving obstacles can be included and/or the problem of constraining orientation can be solved as discussed later herein.

Thus, according to one embodiment of the present invention different kinds of constraints are observed or met respectively, in particular Cartesian and/or joint pose, velocity and/or acceleration limits, force and/or torque limits, static obstacles and/or moving obstacles of a torque- and/or pose-controlled robot, in particular while a human user applies external forces onto an arbitrary point of the robot structure. According to one embodiment:

-   -   the robot continues to follow a programmed task or stack of         tasks while offering compliance within defined constraints;         and/or     -   if a Cartesian limit is approached, a counteracting force, in         particular torque, particularly for orientations, is, preferably         smoothly, induced, advantageously not causing oscillations or         jerky robot motion; and/or     -   the smoothness is guaranteed by specifying maximum velocity,         maximum acceleration and/or maximum force, in particular torque,         values that preferably are always respected; and/or two or more,         in particular all, limits have identical priority, i.e. none of         these limits will be sacrificed in favor of another; and/or     -   besides these quantities, no additional parameters such as a         function for continuous task activation, magnitude of the         Cartesian torque preventing the Cartesian limit or the like need         to be specified.

One advantage of one embodiment of the present invention is that a robot can continue its programmed task while the user interacts. This can save cycle time in human-robot collaborative applications. Another advantage is the simplified control programming. According to one embodiment only maximum Cartesian pose, velocity, and/or acceleration values are/must be specified. These can be set by the user, depending on the application. Torque limits are specified by robot specification or depending on the task(s) according to one embodiment. Cartesian limits are set depending on the shape of the avoided Cartesian obstacle according to one embodiment. This shape is determined from a CAD Model or computer vision according to one embodiment.

Other values that are necessary for state-of-the-art techniques, e.g., a function for continuous task activation, the magnitude of the Cartesian force preventing the Cartesian limit or the like advantageously are not necessary according to one embodiment. These parameters are usually very hard to find, as they strongly depend on the robot structure, its configuration, attached tools etc.

In case of moving obstacles, the motion of the object(s) can be estimated by (computer) vision techniques or by IMU sensors according to one embodiment. In case an object is another robot the encoders of said other robot can be used to specify the motion and velocity of it according to one embodiment.

Although the present invention may particularly advantageously used on robot human interaction, it is not limited thereto but to the contrary can also be used to command the robot in pose or with no (controlled) compliance respectively, which advantageously can produce a high accuracy motion while meeting (all) constraints. According to one embodiment an optimal joint acceleration to produce the (desired) motion of the robot is determined. This acceleration may be integrated to get a joint pose according to one embodiment.

According to one embodiment the robot has two or more tasks to be accomplished. According to one embodiment a prioritization (scheme) is provided to indicate the importance of some task(s) over (an)other(s).

Soft Hierarchy

According to one embodiment a soft hierarchy prioritization (scheme) is implemented: in said soft hierarchy scheme, a weight is assigned for each task depending on its relative importance to other tasks. Consider a robot performing k tasks simultaneously, where task_(t) is of more relative importance to task_(t+i), etc., i.e. priority(task₁)>priority(task₂)>priority(task_(k)). A higher weight w_(t) is given to the more prior task task_(t), w₁>w₂>w_(k). The higher is the ratio between two weights, the stricter is the hierarchy. The soft hierarchy solves only one QP per iteration

For each task, the Hessian matrix H_(t) and gradient vector g_(t) are calculated as described herein, particularly above, and then summed together depending on their associate weights:

$H_{sum} = {{\sum\limits_{t = 1}^{k}{H_{t}g_{sum}}} = {\sum\limits_{t = 1}^{k}g_{t}}}$

Soft priority allows that the lower priority tasks could interfere with a higher priority task.

Strict Hierarchy

According to another embodiment a strict hierarchy prioritization (scheme) is implemented: in said strict hierarchy scheme, priority guaranties the prioritized scheme, lower priority tasks are scarified if they conflict with higher ones.

According to one embodiment of the strict hierarchy prioritization (scheme) the number of QPs solved depends on or equals the number of tasks involved respectively. So in total for k tasks, k QPs are solved per iteration.

For k tasks, in the t^(th) QP, tasks is minimized in the null space of all previous tasks task₀, . . . , task_(t−1). They are included as (in)equality constraints according to one embodiment. The size of the quadratic problem increases in every QP because of the increase in the set of equality constraints.

In particular for two tasks task₁ (high(er) priority), task₂ (low(er) priority):

$\begin{matrix} {1^{st}{QP}:} &  \\ {{\min\limits_{{\overset{¨}{q}}_{1},\tau_{1}}\frac{1}{2}{\overset{¨}{q}}_{1}^{T}H_{1}{\overset{¨}{q}}_{1}} + {{\overset{¨}{q}}_{1}^{T}g_{1}}} &  \end{matrix}$ $\begin{pmatrix} \tau_{\min} \\ {\overset{¨}{Q}}_{\min} \end{pmatrix} \leq \begin{pmatrix} \tau_{1} \\ {\overset{¨}{q}}_{1} \end{pmatrix} \leq \begin{pmatrix} \tau_{\max} \\ {\overset{¨}{Q}}_{\max} \end{pmatrix}$ $\begin{pmatrix} {g + c} \\ {{\overset{¨}{X}}_{\min} - {{\overset{.}{J}}_{c}\overset{.}{q}}} \end{pmatrix} \leq {\begin{pmatrix} I & {- M} \\ 0 & J_{c} \end{pmatrix}\begin{pmatrix} \tau_{1} \\ {\overset{¨}{q}}_{1} \end{pmatrix}} \leq \begin{pmatrix} {g + c} \\ {{\overset{¨}{X}}_{\max} - {{\overset{.}{J}}_{c}\overset{.}{q}}} \end{pmatrix}$ $\begin{matrix} {2^{nd}{QP}:} &  \\ {{\min\limits_{{\overset{¨}{q}}_{2},\tau_{2}}\frac{1}{2}{\overset{¨}{q}}_{2}^{T}H_{2}{\overset{¨}{q}}_{2}} + {{\overset{¨}{q}}_{2}^{T}g_{2}}} &  \end{matrix}$ $\begin{pmatrix} \tau_{\min} \\ {\overset{¨}{Q}}_{\min} \end{pmatrix} \leq \begin{pmatrix} \tau_{2} \\ {\overset{¨}{q}}_{2} \end{pmatrix} \leq \begin{pmatrix} \tau_{\max} \\ {\overset{¨}{Q}}_{\max} \end{pmatrix}$ $\begin{pmatrix} \begin{matrix} {g + c} \\ {{\overset{¨}{X}}_{\min} - {{\overset{.}{J}}_{c}\overset{.}{q}}} \end{matrix} \\ {J_{1}{\overset{¨}{q}}_{1}} \end{pmatrix} \leq {\begin{pmatrix} I & {- M} \\ 0 & J_{c} \\ 0 & J_{1} \end{pmatrix}\begin{pmatrix} \tau_{2} \\ {\overset{¨}{q}}_{2} \end{pmatrix}} \leq \begin{pmatrix} \begin{matrix} {g + c} \\ {{\overset{¨}{X}}_{\max} - {{\overset{.}{J}}_{c}\overset{.}{q}}} \end{matrix} \\ {J_{1}{\overset{¨}{q}}_{1}} \end{pmatrix}$ $\begin{matrix} {{For}{multiple}{tasks}:} &  \\ {{\min\limits_{{\overset{¨}{q}}_{i},\tau_{i}}\frac{1}{2}{\overset{¨}{q}}_{l}^{T}H_{i}{\overset{¨}{q}}_{l}} + {{\overset{¨}{q}}_{l}^{T}g_{i}}} &  \end{matrix}$ $\begin{pmatrix} \tau_{\min} \\ {\overset{¨}{Q}}_{\min} \end{pmatrix} \leq \begin{pmatrix} \tau_{i} \\ {\overset{¨}{q}}_{i} \end{pmatrix}\  \leq \begin{pmatrix} \tau_{\max} \\ {\overset{¨}{Q}}_{\max} \end{pmatrix}$ $\begin{pmatrix} \begin{matrix} {g + c} \\ {{\overset{¨}{X}}_{\min} - {{\overset{.}{J}}_{c}\overset{.}{q}}} \end{matrix} \\ {J_{1}{\overset{¨}{q}}_{1}} \\  \vdots \\ {J_{1}{\overset{¨}{q}}_{1}} \end{pmatrix} \leq {\begin{pmatrix} I & {- M} \\ 0 & J_{c} \\ 0 & J_{i - 1} \\  & \vdots \\ 0 & J_{1} \end{pmatrix}\begin{pmatrix} \tau_{i} \\ {\overset{¨}{q}}_{i} \end{pmatrix}} \leq \begin{pmatrix} \begin{matrix} {g + c} \\ {{\overset{¨}{X}}_{\max} - {{\overset{.}{J}}_{c}\overset{.}{q}}} \end{matrix} \\ {J_{i - 1}{\overset{¨}{q}}_{i - 1}} \\  \vdots \\ {J_{1}{\overset{¨}{q}}_{1}} \end{pmatrix}$

As can be seen from the last line(s), the joint coordinates q_(i) used for task_(i) may in particular be the joint coordinates q_(j) used for one or more higher prioritized task_(j<i) or another sub-set of the robot's joint coordinates fulfilling said equation(s)J_(j){umlaut over (q)}_(j)=J_(j){umlaut over (q)}_(i). Shaping Joint Acceleration Limits

According to one embodiment one or more of the following bounds on the joint ranges, joint velocities and joint accelerations are predetermined:

Q _(min) <q<Q _(max)

V _(min) <{dot over (q)}<V _(max)

A _(min) <{umlaut over (q)}<A _(max)

In particular if the acceleration bounds come from pure kinematic reasoning then according to one embodiment A_(min)=−A_(max).

According to one embodiment the joint acceleration command is kept constant at the computed value {umlaut over (q)}={umlaut over (q)}_(h)={umlaut over (q)}(t_(h)) for a time of duration or step dt respectively. Assuming that at t_(h)=hdt the current joint pose q=q_(h) and velocity {dot over (q)}={dot over (q)}_(h) are both feasible the next joint velocity and pose may be estimated by:

$q_{h + 1} \cong {q_{h} + {{\overset{˙}{q}}_{h}dt} + {\frac{1}{2}{\overset{¨}{q}}_{h}dt^{2}}}$ ${\overset{˙}{q}}_{h + 1} \cong {{\overset{˙}{q}}_{h} + {{\overset{¨}{q}}_{h}dt}}$

Keeping within their bounds yields:

$\frac{V_{\min} - q}{T} \leq {\overset{¨}{q}}_{h} \leq {\frac{V_{\max} - q}{T}{and}}$ ${2\frac{Q_{\min} - q_{h} - {{\overset{˙}{q}}_{h}T}}{T^{2}}} \leq {\overset{¨}{q}}_{h} \leq {2\frac{Q_{\max} - q_{h} - {{\overset{˙}{q}}_{h}T}}{T^{2}}}$

With the constraints given by the inequalities above and those in the previous two equations a box constraint for the command {umlaut over (q)} at time t=t_(h) may be obtained:

{umlaut over (Q)} _(min)(t _(h))≤{umlaut over (q)}≤{umlaut over (Q)} _(max)(t _(h))

According to one embodiment V_(max) and V_(min) are shaped as follows, in particular to reduce the velocity smoothly in the proximity to the joint:

V _(max)=min(V _(max),√{square root over (2A _(max)(Q _(max) −q _(h))))}

V _(min)=max(V _(min),−√{square root over (2A _(max)(q _(h) −Q _(min))))}

Thus, the behavior of the joint coming to its limit can be done smoothly to avoid a big change in the velocity in just one instance of time according to one embodiment. Thereby, the quadratic function may be set to properly shape the velocity bundaries. In this way the velocity may advantageously be reduced before coming to the joint limits. Thus, {umlaut over (Q)}_(min) and {umlaut over (Q)}_(max) can advantageously be included in the QP problem.

Shaping Cartesian Acceleration Limits

According to one embodiment one or more of the following bounds on the Cartesian ranges, Cartesian velocities and Cartesian accelerations are predetermined:

X _(min) <X<X _(max)

V _(min) <{dot over (X)}<V _(max)

A _(min) <{umlaut over (X)}<A _(max)

where X is a vector of the current Cartesian pose of a robot-fixed reference, e.g. the TCP, an end effector or flange respectively, a joint like e.g. the elbow, or the like, in the dimension to be constrained. In particular if the acceleration bounds come from pure kinematic reasoning, then according to one embodiment A_(min)=−A_(max).

According to one embodiment the Cartesian acceleration command is kept constant at the computed value {umlaut over (X)}={umlaut over (X)}_(h)={umlaut over (X)}(t_(h)) for a time of duration or step dt respectively. Assuming that at t_(h)=hdt the current Cartesian pose X=X_(h) and velocity {dot over (X)}={dot over (X)}_(h) are both feasible, the distance to the max limit may be denoted by:

d _(max) =X _(max) −X _(h)

d _(min) =X _(min) −X _(h)

Keeping the next Cartesian velocity and pose

$X_{h + 1} \cong {X_{h} + {{\overset{˙}{X}}_{h}dt} + {\frac{1}{2}{\overset{¨}{X}}_{h}dt^{2}}}$ ${\overset{˙}{X}}_{h + 1} \cong {{\overset{˙}{X}}_{h} + {{\overset{¨}{X}}_{h}dt}}$

within their bounds yield:

$\frac{V_{\min} - X}{T} \leq {\overset{¨}{X}}_{h} \leq {\frac{V_{\max} - X}{T}{and}}$ ${2\frac{d_{\min} - {{\overset{˙}{X}}_{h}T}}{T^{2}}} \leq {\overset{¨}{X}}_{h} \leq {2\frac{d_{\max} - {{\overset{˙}{X}}_{h}T}}{T^{2}}}$

With the constraints given by the inequalities above and those in the previous two equations a box constraint for the command {umlaut over (X)} at time t=t_(h) may be obtained:

{umlaut over (X)} _(min)(t _(h))≤{umlaut over (X)}≤{umlaut over (X)}_(max)(t _(h))

According to one embodiment Vmax and Vmin are shaped as follows, in particular to reduce the velocity smoothly in the proximity to the joint:

V _(max)=min(V _(max),√{square root over (2A _(max)(d _(max))))}

V _(min)=max(V _(min),−√{square root over (2A _(max)(−d _(min))))}

Thus, the behavior of the Cartesian point coming to its limit can be done smoothly to avoid a big change in the velocity in just one instance of time. Thus, {umlaut over (X)}_(min) and {umlaut over (X)}_(max) can advantageously be included in the QP problem.

Computing of Jacobian J_(c) for Position

The Jacobian for the constraint J_(c) is or defines a subspace of the Cartesian space respectively. The columns of the Jacobian represent each joint of the robot, and the rows represent the dimension in which the limit is set. For example the whole Jacobian J for a 7 DoF robot will have the size 6×7, three translational or positional respectively and three rotational coordinates at a Cartesian point e.g. the TCP [x, y, z, α, β, γ] represent the rows of the Jacobian:

$J = \begin{bmatrix} j_{1,1} & j_{1,2} & j_{1,3} & j_{1,4} & j_{1,5} & j_{1,6} & j_{1,7} \\ j_{2,1} & j_{2,2} & j_{2,3} & j_{3,4} & j_{4,5} & j_{5,6} & j_{6,7} \\ j_{3,1} & j_{3,2} & j_{3,3} & j_{3,4} & j_{3,5} & j_{3,6} & j_{3,7} \\ j_{4,1} & j_{4,2} & j_{4,3} & j_{4,4} & j_{4,5} & j_{4,6} & j_{4,7} \\ j_{5,1} & j_{5,2} & j_{5,3} & j_{5,4} & j_{5,5} & j_{5,6} & j_{5,7} \\ j_{6,1} & j_{6,2} & j_{6,3} & j_{6,4} & j_{6,5} & j_{6,6} & j_{6,7} \end{bmatrix}$

If one coordinate, e.g. the coordinate y, is to be limited, e.g. a wall located in a y direction, then, the Jacobian that represents the constrained coordinate, J_(c), will be the corresponding row of J, in said example the second row of J:

J _(c)=[j _(2,1) j _(2,2) j _(2,3) j _(2,4) j _(2,5) j _(2,6) j _(2,7)]

If e.g. the direction z is to be also constrained because the robot should not hit a table, J_(c) will be the second and the third row of J:

$J_{c} = \begin{bmatrix} j_{2,1} & j_{2,2} & j_{2,3} & j_{2,4} & j_{2,5} & j_{2,6} & j_{2,7} \\ j_{3,1} & j_{3,2} & j_{3,3} & j_{3,4} & j_{3,5} & j_{3,6} & j_{3,7} \end{bmatrix}$

According to one embodiment the Jacobian may be the transformation of the velocity of a robot-fixed reference point or coordinate system (origin) respectively, in particular the TCP or another Cartesian point like e.g. a reference point in the robots elbow, and the joint space, i.e. space of the robots joint coordinates, in particular joint angels. For instance if the direction y and z have to be constrained for the Cartesian position of joint 4 (elbow), J_(c) becomes:

$J_{c} = \begin{bmatrix} j_{2,1} & j_{2,2} & j_{2,3} & j_{2,4} & 0 & 0 & 0 \\ j_{3,1} & j_{3,2} & j_{3,3} & j_{3,4} & 0 & 0 & 0 \end{bmatrix}$

Avoidance of Static Obstacles

According to one embodiment, in particular for avoiding obstacles, the Jacobian is rotated and {umlaut over (X)}_(min) and {umlaut over (X)}_(max) are computed in a predetermined direction:

In particular for obstacles like walls or the like that are perpendicular to one of the coordinates a limit value may be defined on one coordinate axis according to one embodiment.

In particular for more complex(ly shaped) obstacles like robot's arm and other environmental objects, one or more virtual, preferably 3 dimensional, geometric models of the objects are determined according to one embodiment which may in particular include the (controlled) robot itself. According to one embodiment one or more (such) virtual models are determined using (computer) vision techniques.

According to one embodiment, in particular using such virtual model(s), the closest distance between the robot and any object and/or the closest point (to any object) on the robot (CP-R) and/or on the, in particular closest, object (CP-O) are computed. After identifying such critical points, a momentary goal is (added or defined respectively) to avoid the collision between these points according to one embodiment. Therefore, advantageously only kinematics parameters of CP-R in the direction of CP-O have to be considered. These parameters may include velocity, acceleration and/or the Jacobian of CP-R in the direction of CP-O, basically the direction along the shortest distance, which is denoted “critical direction” herein. This advantageously can ensure the saturation of its acceleration only along critical direction and allows the CP-R's motion in all other directions.

According to one embodiment the Jacobian is rotated along the critical direction to obtain velocities and acceleration also expressed in this direction. According to one embodiment a rotation matrix is defined or determined respectively which can rotate the coordinate system of critical points in such a way that one of the coordinate axis (e.g. Z-Axis) aligns with the critical direction. Using this rotation matrix Jacobian can be expressed in aligned coordinates.

According to one embodiment said rotation matrix is derived from axis-angle representation of a coordinate orientation, in particular by rotating one axis, e.g. the Z-Axis, until it aligns with the critical direction vector. If for example the Z-Axis needs to be rotated by θ around the rotation axis which is a perpendicular axis to the plane of rotation, in particular the plane that contains both the Z-Axis and the critical direction vector (see FIG. 1 ):

Let CP-R or CPR respectively be the respective point of the robot and denoted by (x₁, x₂, x₃) and CP-O or CPO respectively be the respective point of the obstacle and denoted by (y₁, y₂, y₃). A unit vector u ((c₁, c₂, c₃)) in the critical direction can be obtained by the following equations:

${❘L❘} = \sqrt{\left( {\left( {y_{1} - x_{1}} \right)^{2} + \left( {y_{2} - x_{2}} \right)^{2} + \left( {y_{3} - x_{3}} \right)^{2}} \right)}$ ${c_{1} = \frac{\left( {y_{1} - x_{1}} \right)}{❘L❘}},{c_{2} = \frac{\left( {y_{2} - x_{2}} \right)}{❘L❘}},{c_{3} = \frac{\left( {y_{3} - x_{3}} \right)}{❘L❘}}$

where |L| is the normalized distance between the two points. The axis of rotation should be perpendicular to the plane of rotation. Hence the cross product between the unit critical direction vector and Z-Axis produces a common perpendicular vector which in turn is perpendicular to the plane of rotation. Therefore, the axis of rotation A_(rot)=u×(0, 0, 1). The angle between the Z-Axis z=(0, 0, 1) and the critical direction vector u can be calculated from their dot product according to:

$\theta = {\cos^{- 1}\frac{u \cdot z}{\sqrt{u*z}}}$

Based on said axis A_(rot) and angle θ the required rotation matrix can be determined which by multiplication transforms the representation from base coordinates (O) to aligned (with critical direction) coordinates (C). This rotation is denoted as ^(c)R₀. The equation to determine the coordinates with aligned Z axis is given by:

^(c) CP= ^(c) R ₀*⁰ CP

The maximal or closest distance respectively in this case can be determined according to:

d _(max)=^(c) CPO− ^(c) CPR

where ⁰CP and ^(c)CP are coordinates of critical points represented in original coordinate system and aligned coordinate system respectively. If the coordinates are aligned it is sufficient to find the accelerations along one coordinate axis (in this example the Z-Axis) which provides the Cartesian acceleration in the critical direction:

J _(n)=^(c) R ₀ *J _(t)

where J_(t) are the first 3 rows of J. Thus, J_(c)=J_(n, 3), i.e. the third row of J_(n), because the Z-Axis is aligned with the z direction. {umlaut over (X)}_(min) and {umlaut over (X)}_(max) are determined from the shaping function with the new rotated velocities according to one embodiment:

{dot over (X)}= ^(c) R ₀ ^(c) ĊP

Avoidance of Dynamic Obstacles

To avoid dynamic obstacles, a change in the shaping function is done according to one embodiment to include the velocity of the object relative to the velocity of the robot. Before we assumed that CP-O had zero velocity. If the obstacle is moving, this is not true anymore. Therefore, this velocity {dot over (X)}_(cp-o) may be included in the shaping:

The next Cartesian velocity and pose may be estimated according to:

$X_{h + 1} \cong {X_{h} + {{\overset{˙}{X}}_{h}dt} + {\frac{1}{2}{\overset{¨}{X}}_{h}dt^{2}}}$ ${\overset{˙}{X}}_{h + 1} \cong {{\overset{˙}{X}}_{h} + {{\overset{¨}{X}}_{h}dt}}$

Here {dot over (X)}_(h) is the relative velocity between the critical points.

{dot over (X)} _(h) ={dot over (X)} _(cr-o) −{dot over (X)} _(cp-o)

where {dot over (X)}_(cr-o) is the velocity of the critical point on the robot. Now the boundaries may be shaped as it was explained above with respect to shaping joint acceleration limits, in particular in section “Shaping joit/Cartesian acceleration limits”.

Constraining Orientation

According to one embodiment additionally or alternatively to the position limits in Cartesian space the orientation is constrained.

Lets R_(cur) be a current frame to be constrained, e.g. the end effector frame of the robot, and R_(ref) from where the limits are referenced. Thus, the goal may e.g. be to limit the orientation around one axis of R_(ref) in 45°.

In FIG. 2 both frames are shown, R_(ref) is indicated in dashed lines and R_(cur) in continuous lines. The rotation frames are composed by unit vectors that represent every axis:

R _(ref)=[X _(ref) Y _(ref) Z _(ref)]

R _(cur)=[X _(cur) Y _(cur) Z _(cur)]

Consider a constrained rotation around the x-axis. For this example Z_(cur) must not be separated more than a maximal distance (given by θ_(max)) of the plane Π defined by x_(ref) and Z_(ref) (dotted in FIG. 2 ). To determine this distance, Z_(cur) is projected into the plane and then the distance between these two vectors z_(cur), z_(proj) is determined. To avoid singularities of definition and always have a positive value, e may be computed according to:

θ=atan 2(∥Z _(cur) ×Z _(proj) ∥,Z _(cur) ·Z _(proj))

Then the distance may be determined according to: d_(max)=θ_(max)−θ. Based on said distance the Jacobian to express velocities in the same frame may be determined: the Jacobian J_(r) transforms the joint velocities to the velocity in the orientation of the current frame:

${J_{r}\overset{˙}{q}} = \begin{bmatrix} w_{x} \\ w_{y} \\ w_{z} \end{bmatrix}$

where w_(x), w_(y) and w_(z) are the angular velocities around the vectors X_(cur) Y_(cur) and Z_(cur), respectively. In order to rotate the Jacobian in a way that the angular velocity around the x-axis expresses the angular velocity to move z_(cur) to Z_(proj), w_(x,j) a new rotation frame, R_(j)=[x_(j) y_(j) z_(j)] may be used to rotate the Jacobian. As rotation shall be around x_(j), this vector must be perpendicular to z_(cur) and z_(proj), i.e. x_(j)=z_(proj)×Z_(cur) (thus the positive direction of rotation is going away from the plane). y_(j) is to be the projection of z_(proj) on the plane defined by x_(cur) and y_(cur). To complete the frame z_(j)=z_(cur). This gives the rotated Jacobian:

J _(j) =R _(j) ^(T) J _(r)

The first row of J_(j) relates the joint velocities with the angular velocity w_(x,j):

J _(j,1) {dot over (q)}=w _(x,j)

w_(x,j) and d are the inputs for the shaping of the constraints function and J_(j, 1) will be the Jacobian to determine the constraints in the QP problem: J_(c)=J_(j, 1). Vividly what is happening is that the vector x_(curr) is avoiding to go out of two cones that are symmetrically separated by the plane of x_(ref) and z_(ref).

To constrain orientation around y, analogously the distance between z_(cur) and the plane y_(ref) and z_(ref) may be determined. R_(j) in this case then may be R_(j)=[Z_(proj)×z_(cur) z_(cur)×(Z_(proj)×z_(cur))z_(proj)] where Z_(proj) for this case is the projection of z_(cur) into the plane of y_(ref) and z_(ref).

To constrain orientation around z, analogously the distance between Y_(cur) and the plane y_(ref) and z_(ref) may be determined. R_(j) in this case then may be R_(j)=[y_(proj)×y_(cur) y_(cur)×(y_(proj)×y_(cur)) y_(curr)] where Z_(proj) for this case is the projection of y_(cur) into the plane of y_(ref) and z_(ref).

In order to constrain two orientations according to one embodiment the Jacobians and maximal and minimal acceleration values are stacked or a single cone for one axis is used.

If for example rotation around x and y is to be constrained to 45°, the arrow or vector z_(cur) must not leave the cone as shown in FIG. 3 . The distance is the angle between z_(cur) to z_(ref), determined according to:

θ=atan2(∥Z _(cur) ×Z _(ref) ∥,Z _(cur) ·Z _(ref))

d _(max)=θ_(max)−θ

The rotation matrix to rotate the Jacobian may

R _(j)=[Z _(ref) ×Z _(cur) ,Z _(cur)×(Z _(ref) ×Z _(cur))Z _(curr)].

This may be generalized by

θ=atan 2(∥V _(cur) ×V _(ref) ∥,V _(cur) ·V _(ref))

d=θ _(max−θ)

and

R _(j)=[V _(ref) ×V _(cur) Z _(cur)×(V _(ref) ×V _(cur))V _(curr)].

where V is the unit vector that is not limited (of the corresponding frame), e.g.:

V _(ref/curr) =x _(ref/curr) when constraining y and z

V _(ref/curr) =y _(ref/curr) when constraining xand z

V _(ref/curr) =z _(ref/curr) when constraining x and y

The constrained Jacobian J_(c)=J_(j, 1).

In order to constrain three rotational angles according to one embodiment the Jacobians and the maximal accelerations in the QP problem obtained by computing them for two axes and one axis independently may be stacked.

According to one aspect of the present invention a method to control a robot to perform at least one Cartesian or joint space task comprises: using or applying quadratic programming respectively (so as) to determine joint forces, in particular joint torques, and/or joint accelerations of said robot based one or more cost function(s) which depend(s) on said task.

According to one embodiment, said at least one Cartesian or joint space task is defined or (pre)determined on or in or with respect to one or more coordinates respectively, according to one embodiment position and/or orientation coordinates, in particular of a robot-fixed reference like the TCP, end effector or flange respectively, joint or the like, in Cartesian space or joint coordinates of the robot. The number of said coordinates may be six according to one embodiment or differ from six according to another embodiment.

As described herein, quadratic programming may be used advantageously to control a robot. In particular, quadratic programming may allow to control a robot to perform one or more tasks in a fast(er), (more) reliable and/or smooth(er) way. In particular, as already described in detail, a task f_(t) may comprise or be defined respectively by desired Cartesian or joint acceleration, e.g.:

f _(t) =J _(t) {umlaut over (q)}+J _(t) {dot over (q)}

For example to approach an Cartesian pose X_(d) or follow a Cartesian path may be formulated as a proportional and/or integral and/or differential control law, for example f_(t)=K(X_(d)−X). The cost function depending on the task may be of the form:

$\min\limits_{\overset{¨}{q}}{{{J_{t}\overset{¨}{q}} - \left( {f_{t} - {{\overset{.}{J}}_{t}\overset{.}{q}}} \right)}}^{2}$

This can be written in the quadratic form with H_(t)({umlaut over (q)})=J_(t) ^(T) J_(t) and g_(t)({umlaut over (q)})=−J_(t) ^(T)(f_(t)−{dot over (J)}_(t){dot over (q)}) in Cartesian space control and H_(t)({umlaut over (q)})=I and g_(t)({umlaut over (q)})=−f_(t) in the Joint space control.

As already described herein, according to one embodiment both, joint forces, in particular joint torques, and joint accelerations are both together used as problem variables, which not only can allow advantageously considering (in)equality constrains, in particular Cartesian and/or joint space and/or force, in particular torque, limits, but also may be used in force-control, in particular torque-control (which may particularly useful for compliant control of the robot) as well as in pose control (when using the determined joint accelerations, in particular integrating them into desired joint poses and/or velocities).

As already described herein, according to one embodiment the robot is redundant with respect to the at least one task. Preferably the robot comprises at least six, more preferably at least seven joints, in particular revolute joints. Quadratic programming may be used advantageously to control such redundant robots since the redundancy can be resolved easily in the cost function or quadratic problem respectively.

As already described herein, according to one embodiment the robot is force controlled, in particular torque controlled, and/or compliant controlled. In this way, advantageously human-robot interaction or cooperation can be realized respectively.

As already described herein, according to one embodiment the robot is pose controlled. In this way, advantageously precise robot movement or operation can be realized respectively.

As already described herein, according to one embodiment the robot is controlled to perform simultaneously said at least one Cartesian or joint space task and at least one other Cartesian or joint space task, in particular

-   -   two or more Cartesian space task(s);     -   two or more joint space task(s);     -   one or more Cartesian space task(s) and one or more joint space         task(s).

According to one embodiment, said at least one other Cartesian or joint space task is defined or (pre)determined on or in or with respect to one or more coordinates respectively, according to one embodiment position and/or orientation coordinates, in particular of a robot fixed reference like the TCP, end effector or flange respectively, joint or the like, in Cartesian space or joint coordinates of the robot. The number of said coordinates may be six according to one embodiment or differ from six according to another embodiment.

As already described herein, according to one embodiment quadratic programming is used to determine (the) joint forces, in particular joint torques, and/or joint accelerations of said robot based on said two or more tasks, wherein one or more quadratic problem(s) is/are solved to determine said joint forces, in particular joint torques, and/or joint accelerations.

In particular one quadratic problem may be solved, applying soft hierarchy (scheme) as already described. Additionally or alternatively two or more quadratic problems may be solved, applying strict hierarchy (scheme) as already described, wherein one quadratic problem reflects at least one of the tasks and at least one other quadratic problem reflects at least one other of the tasks, wherein the high(er) prioritized tasks are reflected in (in)equality constraints of the (quadratic problems of the) low(er) prioritized tasks as already described.

As already described herein, according to one embodiment quadratic programming is used to determine the joint forces, in particular joint torques, and/or joint accelerations based on one or more inequality constraints, in particular

-   -   one or more, in particular upper and/or lower, pose limits, in         particular position limits and/or orientation limits, in         Cartesian space; and/or     -   one or more, in particular upper and/or lower, velocity limits         in Cartesian space; and/or     -   one or more, in particular upper and/or lower, acceleration         limit in Cartesian space; and/or     -   one or more, in particular upper and/or lower, pose limits in         joint space; and/or     -   one or more, in particular upper and/or lower, velocity limits         in joint space; and/or     -   one or more, in particular upper and/or lower, acceleration         limit in joint space.

As already described herein, according to one embodiment at least one Cartesian and/or joint velocity and/or acceleration constraint is shaped such that a velocity limit becomes zero at a pose limit.

Additionally or alternatively, according to one embodiment orientation of a robot-fixed reference such as its TCP, end effector or flange respectively, tool or a joint like e.g. the elbow is limited with respect to at least one predetermined direction in Cartesian space as already described herein.

As already described herein, according to one embodiment the robot is controlled to perform the one or more Cartesian and/or joint space tasks while avoiding one or more static obstacles and/or one or more dynamic obstacles. Avoiding one or more (of said) obstacles may in particular be performed based on a Jacobian representing a constraint. Additionally or alternatively, according to one embodiment one or more (of said) obstacles, in particular its pose (relative to the robot) and/or shape, are determined based on a model, preferably a CAD model or the like, of the robots environment and/or based on computer vision.

According to one aspect of the present invention a system is hard- and/or software-wise configured to perform a method as described herein and/or comprises means for controlling the robot to perform the at least one Cartesian or joint space task using quadratic programming to determine joint forces, in particular joint torques, and/or joint accelerations of said robot based on at least one cost function which depends on said task.

According to one embodiment the system or its means respectively comprise:

means for pose control or force control, in particular torque control, and/or for compliant control of the robot based on the determined joint forces, in particular joint torques, and/or joint accelerations; and/or

means for controlling the robot to perform simultaneously said at least one Cartesian or joint space task and at least one other Cartesian or joint space task, wherein quadratic programming is used to determine joint forces, in particular joint torques, and/or joint accelerations of said robot based on said at least two tasks, wherein at least one quadratic problem is solved to determine the joint forces, in particular joint torques, and/or joint accelerations; and/or

means for prioritizing said at least two tasks among each other, in particular by a soft or strict hierarchy; and/or

means for using quadratic programming to determine the joint forces, in particular joint torques, and/or joint accelerations based on at least one inequality constraint, in particular at least one pose limit, in particular position limit and/or orientation limit, at least one velocity limit and/or at least one acceleration limit in Cartesian and/or joint space; and/or

means for shaping at least one Cartesian and/or joint velocity and/or acceleration constraint such that a velocity limit becomes zero at a pose limit; and/or

means for limiting orientation of a robot-fixed reference with respect to at least one predetermined direction in Cartesian space; and/or

means for controlling the robot to perform the one or more Cartesian and/or joint space tasks while avoiding at least one static or dynamic obstacle, in particular based on a Jacobian representing a constraint and/or determining said at least one obstacle based on a model of the robots environment and/or computer vision.

Means in the sense of the present invention can in particular be embodied by or comprise hardware and/or software respectively, in particular one or more programs or program modules and/or at least one, preferably digital, processing unit, in particular microprocessor unit (CPU), graphic card (GPU) or the like, preferably connected to a memory system and/or bus system data- or signal-wise respectively, in particular at least one computer. The processing unit can be adapted to process commands that are implemented as a program stored in a memory system, to receive input signals from a data bus and/or to output signals to a data bus. A memory system can comprise one or more, in particular different and/or digital, storage media, in particular optical, magnetic, solid-state and/or other non-volatile media. The program can be (designed or implemented in) such (a way) that it embodies or is capable of executing a method described herein, so that the processing unit, in particular computer, can carry out the steps of such a method and thus in particular can control the robot. In one embodiment, a computer program product can comprise, in particular, be a, preferably non-volatile, storage medium for storing a program or with a program stored thereon respectively, wherein an execution of this program causes a system or a controller, in particular a computer, to carry out a method as described herein or one or more of its steps.

In one embodiment, one or more, in particular all, steps of the method are carried out completely or partially automatically, in particular by the system or its means.

In one embodiment, the system comprises the robot.

BRIEF DESCRIPTION OF THE DRAWINGS

The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate exemplary embodiments of the invention and, together with a general description of the invention given above, and the detailed description given below, serve to explain the principles of the invention.

FIG. 1 schematically depicts a critical direction between critical points of a robot and an obstacle;

FIG. 2 schematically depicts a reference frame and a current frame;

FIG. 3 depicts the reference frame and current frame with a cone;

FIG. 4 illustrates a method to control the robot according to one embodiment of the present invention; and

FIG. 5 schematically depicts a system with the robot according to one embodiment of the present invention.

DETAILED DESCRIPTION

FIG. 5 shows a system comprising a 7-DOF robot 1 and a robot control(ler) 2 control robot 1 to perform different Cartesian or joint space tasks simultaneously according to one embodiment of the present invention. q₁, . . . q₇ denote the joint poses of robot 1, thus defining its joint space.

FIG. 4 shows a method performed by the robot control(ler) 2 to control robot 1 according to one embodiment of the present invention.

In a first step S10 a user determines the task(s) to be performed and/or pose, in particular position and/or orientation, limits in Cartesian space, e.g. limits for the robots TCP and/or an elbow of robot 1, velocity limits in Cartesian space, e.g. for the robots end effector or flange respectively, and/or pose and/or velocity limits in joint space, e.g. limits for q₁, . . . q₇, and/or their time derivatives respectively. The user may determine the task(s) and/or limits by programing, selecting and/or parametrizing program modules or the like. The robot control(ler) 2 receives corresponding data in step S10.

In step S20 robot control(ler) 2 receives signals indicating the actual joint coordinates and/or their time derivatives and/or actual torques τ₁, . . . τ₇, acting at the joint axes. Additionally it may receive signals from a computer vision system determining obstacles (not shown).

Based thereon robot control(ler) 2 solves the respective quadratic problem(s) to perform the predetermined task(s) while observing or complying with the predetermined limits respectively (step S30).

Joint torques τ₁, . . . τ₇ and joint accelerations {umlaut over (q)}₁, . . . , {umlaut over (q)}₇ are used as optimization problem variables. Thus, robot control(ler) 2 determines optimal joint torques and accelerations in step S30.

According to one embodiment, said optimal joint torques are used in a torque control in step S40, thus realizing a compliant control which allows a human operator to hand-guide the robot while it performs the task(s). According to another embodiment, said optimal joint accelerations are used in a pose control in step S40.

If the task(s) has/have been completed (step S50: “Y”), the method ends (step S60). Otherwise (step S50: “N”), a next cycle or time step is performed.

While the present invention has been illustrated by a description of various embodiments, and while these embodiments have been described in considerable detail, it is not intended to restrict or in any way limit the scope of the appended claims to such de-tail. The various features shown and described herein may be used alone or in any combination. Additional advantages and modifications will readily appear to those skilled in the art. The invention in its broader aspects is therefore not limited to the specific details, representative apparatus and method, and illustrative example shown and described.

Accordingly, departures may be made from such details without departing from the spirit and scope of the general inventive concept. 

What is claimed is: 1-13. (canceled)
 14. A method for controlling a robot to perform at least one Cartesian or joint space task, the robot comprising a plurality of links connected by joints, the method comprising: determining at least one of joint forces or joint accelerations of the robot using quadratic programming and based on at least one cost function which depends on at least one first Cartesian or joint space task; and controlling the robot to perform the at least one first task based on the determined joint forces or joint accelerations.
 15. The method of claim 14, wherein the joint forces are joint torques.
 16. The method of claim 14, wherein at least one of: the robot is redundant with respect to the at least one first task; controlling the robot to perform the at least one first task comprises controlling the robot by force control; or controlling the robot to perform the at least one first task comprises controlling the robot by compliance control.
 17. The method of claim 16, wherein controlling movement of the robot by force control comprises controlling movement of the robot by torque control.
 18. The method of claim 14, wherein at least one of: the robot is redundant with respect to the at least one first task; or controlling the robot to perform the at least one first task comprises controlling the robot by pose control.
 19. The method of claim 14, further comprising: controlling the robot to perform at least one second Cartesian or joint space task simultaneously with the at least one first task; wherein quadratic programming is used to determine at least one of joint forces or joint accelerations of the robot based on the at least one first task and the at least one second task; and wherein at least one quadratic problem is solved to determine the joint forces or joint accelerations.
 20. The method of claim 19, wherein the joint forces comprise joint torques.
 21. The method of claim 19, further comprising: prioritizing the at least one first task and the at least one second task among each other.
 22. The method of claim 21, wherein prioritizing the at least one first task and the at least one second task comprises selectively prioritizing the tasks by a soft hierarchy or a strict hierarchy.
 23. The method of claim 22, wherein the at least one first task and the at least one second task are prioritized by a soft hierarchy by assigning a weight for each task depending on a relative importance of a given task to other tasks.
 24. The method of claim 22, wherein the at least one first task and the at least one second task are prioritized by a strict hierarchy, wherein priority guaranties the prioritized scheme and lower priority tasks are scarified if they conflict with higher priority tasks.
 25. The method of claim 14, wherein using quadratic programming to determine at least one of joint forces or joint accelerations of the robot is based on at least one of: at least one inequality constraint in Cartesian and/or joint space; at least one velocity limit in Cartesian and/or joint space; or at least one acceleration limit in Cartesian and/or joint space.
 26. The method of claim 25, wherein at least one of: the joint forces comprise joint torques; or the at least one inequality constraint comprises at least one of: at least one pose limit, at least one position limit, or at least one orientation limit.
 27. The method of claim 25, wherein at least one of: one or more of at least one Cartesian constraint, at least one joint velocity constraint, or at least one acceleration constraint is shaped such that a velocity limit becomes zero at a pose limit; or an orientation of a robot-fixed reference with respect to at least one predetermined direction in Cartesian space is limited.
 28. The method of claim 14, wherein controlling the robot to perform the at least one task comprises controlling the robot while avoiding at least one static or dynamic obstacle.
 29. The method of claim 28, wherein at least one of: avoiding at least one obstacle is performed based on a Jacobian representing a constraint; or the at least one obstacle is determined based on at least one of a model of the environment surrounding the robot or on computer vision.
 30. A system for controlling a robot to perform at least one Cartesian or joint space task, the system comprising: means for determining at least one of joint forces or joint accelerations of the robot using quadratic programming and based on at least one cost function which depends on the at least one first task; and means for controlling the robot to perform the at least one first task based on the at least one determined joint forces or joint accelerations.
 31. A computer program product for controlling a robot to perform at least one Cartesian or joint space task, the computer program product comprising program code stored on a non-transitory, computer-readable medium, the program code, when executed by a computer, causing the computer to: determine at least one of joint forces or joint accelerations of the robot using quadratic programming and based on at least one cost function which depends on the at least one first task; and control the robot to perform the at least one first task based on the at least one determined joint forces or joint accelerations. 